home *** CD-ROM | disk | FTP | other *** search
/ Giga Games 1 / Giga Games.iso / net / usenet / volume7 / nethack3 / patch7dd < prev    next >
Encoding:
Internet Message Format  |  1990-02-26  |  58.3 KB

  1. Path: uunet!lll-winken!brutus.cs.uiuc.edu!zaphod.mps.ohio-state.edu!think!mintaka!mit-eddie!uw-beaver!zephyr.ens.tek.com!tekred!saab!billr
  2. From: billr@saab.CNA.TEK.COM (Bill Randle)
  3. Newsgroups: comp.sources.games
  4. Subject: v09i030:  NetHack3 -  display oriented dungeons & dragons (Ver. 3.0), Patch7dd
  5. Message-ID: <5244@tekred.CNA.TEK.COM>
  6. Date: 24 Feb 90 01:12:59 GMT
  7. Sender: news@tekred.CNA.TEK.COM
  8. Lines: 2364
  9. Approved: billr@saab.CNA.TEK.COM
  10.  
  11. Submitted-by: Izchak Miller <izchak@linc.cis.upenn.edu>
  12. Posting-number: Volume 9, Issue 30
  13. Archive-name: NetHack3/Patch7dd
  14. Patch-To: NetHack3: Volume 7, Issue 56-93
  15.  
  16.     [This is the last part of patch #7. You should have 30 files,
  17.      Patch7a-Patch7z, Patch7aa-Patch7dd.  -br]
  18.  
  19. #! /bin/sh
  20. # This is a shell archive.  Remove anything before this line, then unpack
  21. # it by saving it into a file and typing "sh file".  To overwrite existing
  22. # files, type "sh file -c".  You can also feed this as standard input via
  23. # unshar, or by typing "sh <file", e.g..  If this archive is complete, you
  24. # will see the following message at the end:
  25. #        "End of archive 30 (of 30)."
  26. # Contents:  patch7.02
  27. # Wrapped by billr@saab on Wed Feb 21 10:04:22 1990
  28. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  29. if test -f 'patch7.02' -a "${1}" != "-c" ; then 
  30.   echo shar: Renaming existing file \"'patch7.02'\" to \"'patch7.02.orig'\"
  31.   mv -f 'patch7.02' 'patch7.02.orig'
  32. fi
  33. echo shar: Extracting \"'patch7.02'\" \(55250 characters\)
  34. sed "s/^X//" >'patch7.02' <<'END_OF_FILE'
  35. X*** src/Old/cmd.c    Mon Feb 19 17:55:04 1990
  36. X--- src/cmd.c    Fri Feb  2 18:21:18 1990
  37. X***************
  38. X*** 6,92 ****
  39. X  #include    "func_tab.h"
  40. X  
  41. X  #ifdef DUMB    /* stuff commented out in extern.h, but needed here */
  42. X! extern int doapply(); /**/
  43. X! extern int dorub(); /**/
  44. X! extern int dojump(); /**/
  45. X! extern int doextlist(); /**/
  46. X! extern int dodrop(); /**/
  47. X! extern int doddrop(); /**/
  48. X! extern int dodown(); /**/
  49. X! extern int doup(); /**/
  50. X! extern int donull(); /**/
  51. X! extern int dowipe(); /**/
  52. X! extern int do_mname(); /**/
  53. X! extern int ddocall(); /**/
  54. X! extern int dotakeoff(); /**/
  55. X! extern int doremring(); /**/
  56. X! extern int dowear(); /**/
  57. X! extern int doputon(); /**/
  58. X! extern int doddoremarm(); /**/
  59. X! extern int dokick(); /**/
  60. X! extern int dothrow(); /**/
  61. X! extern int doeat(); /**/
  62. X! extern int done2(); /**/
  63. X! extern int doengrave(); /**/
  64. X! extern int dopickup(); /**/
  65. X! extern int ddoinv(); /**/
  66. X! extern int dotypeinv(); /**/
  67. X! extern int dolook(); /**/
  68. X! extern int doprgold(); /**/
  69. X! extern int doprwep(); /**/
  70. X! extern int doprarm(); /**/
  71. X! extern int doprring(); /**/
  72. X! extern int dopramulet(); /**/
  73. X! extern int doprtool(); /**/
  74. X! extern int dosuspend(); /**/
  75. X! extern int doforce(); /**/
  76. X! extern int doopen(); /**/
  77. X! extern int doclose(); /**/
  78. X! extern int dosh(); /**/
  79. X! extern int dodiscovered(); /**/
  80. X! extern int doset(); /**/
  81. X! extern int dotogglepickup(); /**/
  82. X! extern int dowhatis(); /**/
  83. X! extern int dowhatdoes(); /**/
  84. X! extern int dohelp(); /**/
  85. X! extern int dohistory(); /**/
  86. X! extern int doloot(); /**/
  87. X! extern int dodrink(); /**/
  88. X! extern int dodip(); /**/
  89. X! extern int dosacrifice(); /**/
  90. X! extern int dopray(); /**/
  91. X! extern int doturn(); /**/
  92. X! extern int doredraw(); /**/
  93. X! extern int doread(); /**/
  94. X! extern int dosave(); /**/
  95. X! extern int dosave0(); /**/
  96. X! extern int dosearch(); /**/
  97. X  extern int FDECL(dosearch0, (int)); /**/
  98. X! extern int doidtrap(); /**/
  99. X! extern int dopay(); /**/
  100. X! extern int dosit(); /**/
  101. X! extern int dotalk(); /**/
  102. X! extern int docast(); /**/
  103. X! extern int dovspell(); /**/
  104. X! extern int doredotopl(); /**/
  105. X! extern int dotele(); /**/
  106. X! extern int dountrap(); /**/
  107. X! extern int doversion(); /**/
  108. X! extern int dowield(); /**/
  109. X! extern int dozap(); /**/
  110. X  #endif /* DUMB */
  111. X  
  112. X! #ifndef OVERLAY
  113. X! static 
  114. X! #endif
  115. X! int (*timed_occ_fn)();
  116. X! #ifdef POLYSELF
  117. X! #ifndef OVERLAY
  118. X! static 
  119. X  #endif
  120. X! int domonability();
  121. X  #endif
  122. X  
  123. X  /* Count down by decrementing multi */
  124. X  #ifndef OVERLAY
  125. X  static 
  126. X--- 6,122 ----
  127. X  #include    "func_tab.h"
  128. X  
  129. X  #ifdef DUMB    /* stuff commented out in extern.h, but needed here */
  130. X! extern int NDECL(doapply); /**/
  131. X! extern int NDECL(dorub); /**/
  132. X! extern int NDECL(dojump); /**/
  133. X! extern int NDECL(doextlist); /**/
  134. X! extern int NDECL(dodrop); /**/
  135. X! extern int NDECL(doddrop); /**/
  136. X! extern int NDECL(dodown); /**/
  137. X! extern int NDECL(doup); /**/
  138. X! extern int NDECL(donull); /**/
  139. X! extern int NDECL(dowipe); /**/
  140. X! extern int NDECL(do_mname); /**/
  141. X! extern int NDECL(ddocall); /**/
  142. X! extern int NDECL(dotakeoff); /**/
  143. X! extern int NDECL(doremring); /**/
  144. X! extern int NDECL(dowear); /**/
  145. X! extern int NDECL(doputon); /**/
  146. X! extern int NDECL(doddoremarm); /**/
  147. X! extern int NDECL(dokick); /**/
  148. X! extern int NDECL(dothrow); /**/
  149. X! extern int NDECL(doeat); /**/
  150. X! extern int NDECL(done2); /**/
  151. X! extern int NDECL(doengrave); /**/
  152. X! extern int NDECL(dopickup); /**/
  153. X! extern int NDECL(ddoinv); /**/
  154. X! extern int NDECL(dotypeinv); /**/
  155. X! extern int NDECL(dolook); /**/
  156. X! extern int NDECL(doprgold); /**/
  157. X! extern int NDECL(doprwep); /**/
  158. X! extern int NDECL(doprarm); /**/
  159. X! extern int NDECL(doprring); /**/
  160. X! extern int NDECL(dopramulet); /**/
  161. X! extern int NDECL(doprtool); /**/
  162. X! extern int NDECL(dosuspend); /**/
  163. X! extern int NDECL(doforce); /**/
  164. X! extern int NDECL(doopen); /**/
  165. X! extern int NDECL(doclose); /**/
  166. X! extern int NDECL(dosh); /**/
  167. X! extern int NDECL(dodiscovered); /**/
  168. X! extern int NDECL(doset); /**/
  169. X! extern int NDECL(dotogglepickup); /**/
  170. X! extern int NDECL(dowhatis); /**/
  171. X! extern int NDECL(dowhatdoes); /**/
  172. X! extern int NDECL(dohelp); /**/
  173. X! extern int NDECL(dohistory); /**/
  174. X! extern int NDECL(doloot); /**/
  175. X! extern int NDECL(dodrink); /**/
  176. X! extern int NDECL(dodip); /**/
  177. X! extern int NDECL(dosacrifice); /**/
  178. X! extern int NDECL(dopray); /**/
  179. X! extern int NDECL(doturn); /**/
  180. X! extern int NDECL(doredraw); /**/
  181. X! extern int NDECL(doread); /**/
  182. X! extern int NDECL(dosave); /**/
  183. X! extern int NDECL(dosave0); /**/
  184. X! extern int NDECL(dosearch); /**/
  185. X  extern int FDECL(dosearch0, (int)); /**/
  186. X! extern int NDECL(doidtrap); /**/
  187. X! extern int NDECL(dopay); /**/
  188. X! extern int NDECL(dosit); /**/
  189. X! extern int NDECL(dotalk); /**/
  190. X! extern int NDECL(docast); /**/
  191. X! extern int NDECL(dovspell); /**/
  192. X! extern int NDECL(doredotopl); /**/
  193. X! extern int NDECL(dotele); /**/
  194. X! extern int NDECL(dountrap); /**/
  195. X! extern int NDECL(doversion); /**/
  196. X! extern int NDECL(doextversion); /**/
  197. X! extern int NDECL(dowield); /**/
  198. X! extern int NDECL(dozap); /**/
  199. X  #endif /* DUMB */
  200. X  
  201. X! #ifdef OVL1
  202. X! 
  203. X! static int NDECL((*timed_occ_fn));
  204. X! 
  205. X! #endif /* OVL1 */
  206. X! 
  207. X! #ifndef OVERLAY
  208. X! static int NDECL(timed_occupation);
  209. X! static int NDECL(doextcmd);
  210. X! # ifdef POLYSELF
  211. X! static int NDECL(domonability);
  212. X! # endif
  213. X! # ifdef WIZARD
  214. X! static int NDECL(wiz_wish);
  215. X! static int NDECL(wiz_identify);
  216. X! static int NDECL(wiz_map);
  217. X! static int NDECL(wiz_genesis);
  218. X! static int NDECL(wiz_where);
  219. X! static int NDECL(wiz_detect);
  220. X! static int NDECL(wiz_level_tele);
  221. X! # endif
  222. X! # ifdef EXPLORE_MODE
  223. X! static int NDECL(enter_explore_mode);
  224. X! # endif
  225. X! # if defined(WIZARD) || defined(EXPLORE_MODE)
  226. X! static int NDECL(wiz_attributes);
  227. X! # endif
  228. X! #endif /* OVERLAY */
  229. X! 
  230. X! #ifdef REDO
  231. X! static char NDECL(popch);
  232. X  #endif
  233. X! 
  234. X! #ifdef STUPID_CPP
  235. X! static char FDECL(unctrl, (CHAR_P));
  236. X! static char FDECL(unmeta, (CHAR_P));
  237. X  #endif
  238. X  
  239. X+ #ifdef OVL1
  240. X+ 
  241. X  /* Count down by decrementing multi */
  242. X  #ifndef OVERLAY
  243. X  static 
  244. X***************
  245. X*** 124,131 ****
  246. X   */
  247. X  void
  248. X  set_occupation(fn, txt, xtime)
  249. X! int (*fn)();
  250. X! char *txt;
  251. X  int xtime;
  252. X  {
  253. X      if (xtime) {
  254. X--- 154,161 ----
  255. X   */
  256. X  void
  257. X  set_occupation(fn, txt, xtime)
  258. X! int NDECL((*fn));
  259. X! const char *txt;
  260. X  int xtime;
  261. X  {
  262. X      if (xtime) {
  263. X***************
  264. X*** 199,204 ****
  265. X--- 229,237 ----
  266. X  }
  267. X  #endif /* REDO */
  268. X  
  269. X+ #endif /* OVL1 */
  270. X+ #ifdef OVLB
  271. X+ 
  272. X  #ifndef OVERLAY
  273. X  static 
  274. X  #endif
  275. X***************
  276. X*** 278,283 ****
  277. X--- 311,346 ----
  278. X  }
  279. X  #endif
  280. X  
  281. X+ #ifdef EXPLORE_MODE
  282. X+ #ifndef OVERLAY
  283. X+ static 
  284. X+ #endif
  285. X+ int
  286. X+ enter_explore_mode()
  287. X+ {
  288. X+     if(!discover && !wizard) {
  289. X+         pline("Beware!  From discovery mode there will be no return to normal game.");
  290. X+         more();
  291. X+ #ifndef MACOS
  292. X+         pline("Do you want to enter discovery mode? ");
  293. X+          if(yn() == 'y') {
  294. X+ #else
  295. X+         if(!flags.silent) SysBeep(1);
  296. X+         if(UseMacAlertText(128, "Enter discovery mode ?") == 1) {
  297. X+ #endif
  298. X+             clrlin();
  299. X+             pline("You are now in non-scoring discovery mode.");
  300. X+             discover = TRUE;
  301. X+         }
  302. X+         else {
  303. X+             clrlin();
  304. X+             pline("Resuming normal game.");
  305. X+         }
  306. X+     }
  307. X+     return 0;
  308. X+ }
  309. X+ #endif
  310. X+ 
  311. X  #ifdef WIZARD
  312. X  #ifndef OVERLAY
  313. X  static 
  314. X***************
  315. X*** 462,468 ****
  316. X      }
  317. X  #ifdef WIZARD
  318. X      if (wizard) {
  319. X!         Sprintf(buf, "Your luck is %d.", u.uluck);
  320. X          cornline(1, buf);
  321. X      }
  322. X  #endif
  323. X--- 525,531 ----
  324. X      }
  325. X  #ifdef WIZARD
  326. X      if (wizard) {
  327. X!         Sprintf(buf, "Your luck is %d.", Luck);
  328. X          cornline(1, buf);
  329. X      }
  330. X  #endif
  331. X***************
  332. X*** 486,491 ****
  333. X--- 549,557 ----
  334. X  }
  335. X  #endif /* WIZARD || EXPLORE_MODE */
  336. X  
  337. X+ #endif /* OVLB */
  338. X+ #ifdef OVL1
  339. X+ 
  340. X  #ifndef M
  341. X  #define M(c)        (0x80 | (c))
  342. X  #endif
  343. X***************
  344. X*** 573,578 ****
  345. X--- 639,645 ----
  346. X      {M('u'), dountrap},
  347. X      {'v', doversion},
  348. X      {'V', dohistory},
  349. X+     {M('v'), doextversion},
  350. X      {'w', dowield},
  351. X      {'W', dowear},
  352. X      {M('w'), dowipe},
  353. X***************
  354. X*** 579,584 ****
  355. X--- 646,654 ----
  356. X  #ifdef SPELLS
  357. X      {'x', dovspell},            /* Mike Stephenson */
  358. X  #endif
  359. X+ #ifdef EXPLORE_MODE
  360. X+     {'X', enter_explore_mode},
  361. X+ #endif
  362. X  /*    'y', 'Y' : go nw */
  363. X      {'z', dozap},
  364. X  #ifdef SPELLS
  365. X***************
  366. X*** 631,636 ****
  367. X--- 701,708 ----
  368. X      "sit", "sit down", dosit,
  369. X      "turn", "turn undead", doturn,
  370. X      "untrap", "untrap something", dountrap,
  371. X+     "version", "print compile time options for this version of NetHack",
  372. X+         doextversion,
  373. X      "wipe", "wipe off your face", dowipe,
  374. X      "?", "get this list of extended commands", doextlist,
  375. X      NULL, NULL, donull
  376. X***************
  377. X*** 716,722 ****
  378. X          flags.run = 3;
  379. X          goto rush;
  380. X      }
  381. X!     if(*cmd == 'm' && movecmd(cmd[1])) {
  382. X          flags.run = 0;
  383. X          flags.nopick = 1;
  384. X          goto walk;
  385. X--- 788,795 ----
  386. X          flags.run = 3;
  387. X          goto rush;
  388. X      }
  389. X!     if((*cmd == 'm' || (flags.num_pad & *cmd == '-')) &&
  390. X!         movecmd(cmd[1])) {
  391. X          flags.run = 0;
  392. X          flags.nopick = 1;
  393. X          goto walk;
  394. X***************
  395. X*** 726,731 ****
  396. X--- 799,810 ----
  397. X          flags.nopick = 1;
  398. X          goto rush;
  399. X      }
  400. X+     if(flags.num_pad && *cmd == '0') {
  401. X+             (void)ddoinv();    /* A convenience borrowed from the PC */
  402. X+         flags.move = 0;
  403. X+         multi = 0;
  404. X+         return;
  405. X+     }
  406. X      while(tlist->f_char) {
  407. X          if((*cmd & 0xff) == (tlist->f_char & 0xff)){
  408. X              /* Special case of *cmd == ' ' handled here */
  409. X***************
  410. X*** 735,742 ****
  411. X              /* Now control-A can stop lengthy commands */
  412. X              /* in the PC version only -- use ^C-N otherwise */
  413. X              if (tlist->f_text && !occupation && multi)
  414. X!                 set_occupation(tlist->f_funct, tlist->f_text,
  415. X!                     multi);
  416. X              res = (*(tlist->f_funct))();
  417. X              if(!res) {
  418. X                  flags.move = 0;
  419. X--- 814,826 ----
  420. X              /* Now control-A can stop lengthy commands */
  421. X              /* in the PC version only -- use ^C-N otherwise */
  422. X              if (tlist->f_text && !occupation && multi)
  423. X! #ifdef __GNULINT__
  424. X!                 set_occupation(tlist->f_funct,
  425. X!                         tlist->f_text, multi);
  426. X! #else
  427. X!                 set_occupation(((struct func_tab *)tlist)->f_funct,
  428. X!                     tlist->f_text, multi);
  429. X! #endif
  430. X              res = (*(tlist->f_funct))();
  431. X              if(!res) {
  432. X                  flags.move = 0;
  433. X***************
  434. X*** 810,816 ****
  435. X  movecmd(sym)    /* also sets u.dz, but returns false for <> */
  436. X  char sym;
  437. X  {
  438. X!     register char *dp;
  439. X      register const char *sdp = flags.num_pad ? ndir : sdir;
  440. X  
  441. X      u.dz = 0;
  442. X--- 894,900 ----
  443. X  movecmd(sym)    /* also sets u.dz, but returns false for <> */
  444. X  char sym;
  445. X  {
  446. X!     register const char *dp;
  447. X      register const char *sdp = flags.num_pad ? ndir : sdir;
  448. X  
  449. X      u.dz = 0;
  450. X***************
  451. X*** 827,832 ****
  452. X--- 911,919 ----
  453. X      return !u.dz;
  454. X  }
  455. X  
  456. X+ #endif /* OVL1 */
  457. X+ #ifdef OVLB
  458. X+ 
  459. X  int
  460. X  getdir(s)
  461. X  boolean s;
  462. X***************
  463. X*** 865,870 ****
  464. X--- 952,960 ----
  465. X      return;
  466. X  }
  467. X  
  468. X+ #endif /* OVLB */
  469. X+ #ifdef OVL0
  470. X+ 
  471. X  int
  472. X  isok(x,y)
  473. X  register int x, y;
  474. X***************
  475. X*** 872,874 ****
  476. X--- 962,966 ----
  477. X      /* x corresponds to curx, so x==1 is the first column. Ach. %% */
  478. X      return x >= 1 && x <= COLNO-1 && y >= 0 && y <= ROWNO-1;
  479. X  }
  480. X+ 
  481. X+ #endif /* OVL0 */
  482. X*** src/Old/dbridge.c    Mon Feb 19 17:55:39 1990
  483. X--- src/dbridge.c    Fri Feb  2 18:22:08 1990
  484. X***************
  485. X*** 12,17 ****
  486. X--- 12,37 ----
  487. X  
  488. X  #include "hack.h"
  489. X  
  490. X+ #ifdef STRONGHOLD
  491. X+ static void FDECL(redosym, (int, int));
  492. X+ static void FDECL(get_wall_for_db, (int *, int *));
  493. X+ static struct entity *FDECL(e_at, (int, int));
  494. X+ static void FDECL(m_to_e, (struct monst *, struct entity *));
  495. X+ static void FDECL(u_to_e, (struct entity *));
  496. X+ static void FDECL(set_entity, (int, int, struct entity *));
  497. X+ static char *FDECL(e_nam, (struct entity *));
  498. X+ /* static char *FDECL(Enam, (struct entity *)); */ /* unused */
  499. X+ static char *FDECL(E_phrase, (struct entity *, const char *));
  500. X+ static boolean FDECL(e_survives_at, (struct entity *, int, int));
  501. X+ static void FDECL(e_died, (struct entity *, int, int));
  502. X+ static boolean FDECL(automiss, (struct entity *));
  503. X+ static boolean FDECL(e_missed, (struct entity *, BOOLEAN_P));
  504. X+ static boolean FDECL(e_jumps, (struct entity *));
  505. X+ static void FDECL(do_entity, (struct entity *));
  506. X+ #endif
  507. X+ 
  508. X+ #ifdef OVL0
  509. X+ 
  510. X  boolean
  511. X  is_pool(x,y)
  512. X  int x,y;
  513. X***************
  514. X*** 24,30 ****
  515. X--- 44,55 ----
  516. X         return FALSE;
  517. X  }
  518. X  
  519. X+ #endif /* OVL0 */
  520. X+ 
  521. X  #ifdef STRONGHOLD
  522. X+ 
  523. X+ #ifdef OVL1
  524. X+ 
  525. X  void
  526. X  initsym(x,y)
  527. X  int x,y;
  528. X***************
  529. X*** 88,93 ****
  530. X--- 113,121 ----
  531. X      return (-1);
  532. X  }
  533. X  
  534. X+ #endif /* OVL1 */
  535. X+ #ifdef OVL1
  536. X+ 
  537. X  /*
  538. X   * Use is_db_wall where you want to verify that a
  539. X   * drawbridge "wall" is UP in the location x, y
  540. X***************
  541. X*** 101,106 ****
  542. X--- 129,137 ----
  543. X          levl[x][y].diggable & W_GATEWAY);
  544. X  }
  545. X  
  546. X+ #endif /* OVL1 */
  547. X+ #ifdef OVLB
  548. X+ 
  549. X  /*
  550. X   * Return true with x,y pointing to the drawbridge if x,y initially indicate
  551. X   * a drawbridge or drawbridge wall.
  552. X***************
  553. X*** 169,174 ****
  554. X--- 200,208 ----
  555. X              wall = VWALL;
  556. X              x2++;
  557. X              break;
  558. X+         default:
  559. X+             impossible("bad direction in create_drawbridge");
  560. X+             /* fall through */
  561. X          case DB_WEST:
  562. X              wall = VWALL;
  563. X              x2--;
  564. X***************
  565. X*** 308,314 ****
  566. X  static char *
  567. X  E_phrase(etmp, verb)
  568. X  struct entity *etmp;
  569. X! char *verb;
  570. X  {
  571. X      char wholebuf[80], verbbuf[30];
  572. X  
  573. X--- 342,348 ----
  574. X  static char *
  575. X  E_phrase(etmp, verb)
  576. X  struct entity *etmp;
  577. X! const char *verb;
  578. X  {
  579. X      char wholebuf[80], verbbuf[30];
  580. X  
  581. X***************
  582. X*** 427,433 ****
  583. X  
  584. X      if (is_flyer(etmp->edata) && 
  585. X          (is_u(etmp)? !Sleeping : 
  586. X!          (!etmp->emon->mfroz && !etmp->emon->msleep)))
  587. X                            /* flying requires mobility */
  588. X          misses = 5;    /* out of 8 */    
  589. X      else
  590. X--- 461,467 ----
  591. X  
  592. X      if (is_flyer(etmp->edata) && 
  593. X          (is_u(etmp)? !Sleeping : 
  594. X!          (etmp->emon->mcanmove && !etmp->emon->msleep)))
  595. X                            /* flying requires mobility */
  596. X          misses = 5;    /* out of 8 */    
  597. X      else
  598. X***************
  599. X*** 461,467 ****
  600. X      int tmp = 4;         /* out of 10 */
  601. X  
  602. X      if (is_u(etmp)? (Sleeping || Fumbling) : 
  603. X!                 (etmp->emon->mfroz || etmp->emon->msleep || 
  604. X               !etmp->edata->mmove))
  605. X          return(FALSE);
  606. X  
  607. X--- 495,501 ----
  608. X      int tmp = 4;         /* out of 10 */
  609. X  
  610. X      if (is_u(etmp)? (Sleeping || Fumbling) : 
  611. X!                 (!etmp->emon->mcanmove || etmp->emon->msleep || 
  612. X               !etmp->edata->mmove))
  613. X          return(FALSE);
  614. X  
  615. X***************
  616. X*** 664,669 ****
  617. X--- 698,704 ----
  618. X                  pline("%s behind the drawbridge.",
  619. X                                    E_phrase(etmp, "disappear"));
  620. X          if (!e_survives_at(etmp, etmp->ex, etmp->ey)) {
  621. X+             killer_format = KILLED_BY_AN;
  622. X              killer = "closing drawbridge";
  623. X              e_died(etmp, 0, CRUSHING);         /* no message */
  624. X              return;
  625. X***************
  626. X*** 697,703 ****
  627. X                  else
  628. X                        pline("%s into the moat.",
  629. X                                    E_phrase(etmp, "fall"));
  630. X!         killer = "fall from a drawbridge";
  631. X          e_died(etmp, e_inview? 1 : 0,        /* CRUSHING is arbitrary */
  632. X                 (is_pool(etmp->ex, etmp->ey))? DROWNING : CRUSHING);
  633. X                                             /* corpse */
  634. X--- 732,739 ----
  635. X                  else
  636. X                        pline("%s into the moat.",
  637. X                                    E_phrase(etmp, "fall"));
  638. X!         killer_format = NO_KILLER_PREFIX;
  639. X!         killer = "fell from a drawbridge";
  640. X          e_died(etmp, e_inview? 1 : 0,        /* CRUSHING is arbitrary */
  641. X                 (is_pool(etmp->ex, etmp->ey))? DROWNING : CRUSHING);
  642. X                                             /* corpse */
  643. X***************
  644. X*** 832,837 ****
  645. X--- 868,874 ----
  646. X              if (e_inview)
  647. X                  pline("%s blown apart by flying debris",
  648. X                              E_phrase(etmp2, "are"));
  649. X+             killer_format = KILLED_BY_AN;
  650. X              killer = "exploding drawbridge";
  651. X              e_died(etmp2, e_inview? 2 : 3, CRUSHING);/* no corpse */
  652. X          }          /* nothing which is vulnerable can survive this */
  653. X***************
  654. X*** 862,867 ****
  655. X--- 899,905 ----
  656. X                      pline("%s from shrapnel", 
  657. X                            E_phrase(etmp1, "die"));
  658. X  #endif
  659. X+             killer_format = KILLED_BY_AN;
  660. X              killer = "collapsing drawbridge";
  661. X              e_died(etmp1, e_inview? 0 : 1, CRUSHING);   /* corpse */
  662. X          }
  663. X***************
  664. X*** 869,873 ****
  665. X--- 907,914 ----
  666. X      redosym(x,y);
  667. X      redosym(x2,y2);
  668. X  }
  669. X+ 
  670. X+ 
  671. X+ #endif /* OVLB */
  672. X  
  673. X  #endif /* STRONGHOLD /**/
  674. X*** src/Old/decl.c    Mon Feb 19 17:56:16 1990
  675. X--- src/decl.c    Sun Feb 18 16:37:36 1990
  676. X***************
  677. X*** 41,48 ****
  678. X  int doorindex = 0;
  679. X  
  680. X  char *save_cm = 0;
  681. X! char *killer = 0;
  682. X! char *nomovemsg = 0;
  683. X  const char nul[40] = DUMMY;        /* contains zeros */
  684. X  char plname[PL_NSIZ] = DUMMY;        /* player name */
  685. X  char pl_character[PL_CSIZ] = DUMMY;
  686. X--- 41,49 ----
  687. X  int doorindex = 0;
  688. X  
  689. X  char *save_cm = 0;
  690. X! int killer_format = 0;
  691. X! const char *killer = 0;
  692. X! const char *nomovemsg = 0;
  693. X  const char nul[40] = DUMMY;        /* contains zeros */
  694. X  char plname[PL_NSIZ] = DUMMY;        /* player name */
  695. X  char pl_character[PL_CSIZ] = DUMMY;
  696. X***************
  697. X*** 61,69 ****
  698. X  #endif
  699. X  
  700. X  #ifdef SMALLDATA
  701. X! char *occtxt = 0;
  702. X  #else
  703. X! char *occtxt = DUMMY;
  704. X  #endif
  705. X  const char quitchars[] = " \r\n\033";
  706. X  const char vowels[] = "aeiouAEIOU";
  707. X--- 62,70 ----
  708. X  #endif
  709. X  
  710. X  #ifdef SMALLDATA
  711. X! const char *occtxt = 0;
  712. X  #else
  713. X! const char *occtxt = DUMMY;
  714. X  #endif
  715. X  const char quitchars[] = " \r\n\033";
  716. X  const char vowels[] = "aeiouAEIOU";
  717. X***************
  718. X*** 87,93 ****
  719. X--- 88,98 ----
  720. X  #endif
  721. X  
  722. X  #ifdef TEXTCOLOR
  723. X+ # ifdef TOS
  724. X+ const char *hilites[MAXCOLORS];    /* terminal escapes for the various colors */
  725. X+ # else
  726. X  char *hilites[MAXCOLORS];    /* terminal escapes for the various colors */
  727. X+ # endif
  728. X  #endif
  729. X  #ifdef MSDOS
  730. X  char hackdir[PATHLEN];        /* where rumors, help, record are */
  731. X***************
  732. X*** 202,239 ****
  733. X  symbol_array savesyms = DUMMY;
  734. X  #endif
  735. X  
  736. X! char *explainsyms[MAXPCHARS] = {
  737. X!     "a dark part of a room", "a wall", "a wall",
  738. X!     "a wall", "a wall", "a wall",
  739. X!     "a wall", "a wall", "a wall",
  740. X!     "a wall", "a wall", "a wall",
  741. X!     "a wall", "a wall", "a wall",
  742. X!     "a wall", "a doorway", "an open door",
  743. X!     "an open door", "a closed door", "the floor of a room",
  744. X!     "a corridor", "a staircase up", "a staircase down",
  745. X!     "a trap", "a web", "a water filled area",
  746. X  #ifdef FOUNTAINS
  747. X!     "a fountain",
  748. X  #else
  749. X      "",
  750. X  #endif
  751. X  #ifdef SINKS
  752. X!     "a sink",
  753. X  #else
  754. X      "",
  755. X  #endif
  756. X  #ifdef THRONES
  757. X!     "an opulent throne",
  758. X  #else
  759. X      "",
  760. X  #endif
  761. X  #ifdef ALTARS
  762. X!     "an altar",
  763. X  #else
  764. X      "",
  765. X  #endif
  766. X  #ifdef STRONGHOLD
  767. X!     "a ladder up", "a ladder down", "a drawbridge", "a drawbridge"
  768. X  #else
  769. X      "", "", "", ""
  770. X  #endif
  771. X--- 207,244 ----
  772. X  symbol_array savesyms = DUMMY;
  773. X  #endif
  774. X  
  775. X! const char *explainsyms[MAXPCHARS] = {
  776. X!     "dark part of a room", "wall", "wall",
  777. X!     "wall", "wall", "wall",
  778. X!     "wall", "wall", "wall",
  779. X!     "wall", "wall", "wall",
  780. X!     "wall", "wall", "wall",
  781. X!     "wall", "doorway", "open door",
  782. X!     "open door", "closed door", "floor of a room",
  783. X!     "corridor", "staircase up", "staircase down",
  784. X!     "trap", "web", "water filled area",
  785. X  #ifdef FOUNTAINS
  786. X!     "fountain",
  787. X  #else
  788. X      "",
  789. X  #endif
  790. X  #ifdef SINKS
  791. X!     "sink",
  792. X  #else
  793. X      "",
  794. X  #endif
  795. X  #ifdef THRONES
  796. X!     "opulent throne",
  797. X  #else
  798. X      "",
  799. X  #endif
  800. X  #ifdef ALTARS
  801. X!     "altar",
  802. X  #else
  803. X      "",
  804. X  #endif
  805. X  #ifdef STRONGHOLD
  806. X!     "ladder up", "ladder down", "drawbridge", "drawbridge"
  807. X  #else
  808. X      "", "", "", ""
  809. X  #endif
  810. X***************
  811. X*** 273,275 ****
  812. X--- 278,341 ----
  813. X  
  814. X  const char nothing_happens[] = "Nothing happens.";
  815. X  const char thats_enough_tries[] = "That's enough tries!";
  816. X+ 
  817. X+ const char monsyms[] = { S_HUMAN, S_GHOST, S_ANT, S_BLOB, S_COCKATRICE, S_DOG,
  818. X+ S_EYE, S_FELINE, S_GREMLIN, S_HUMANOID, S_IMP, S_JELLY, S_KOBOLD,
  819. X+ S_LEPRECHAUN, S_MIMIC, S_NYMPH, S_ORC, S_PIERCER, S_QUADRUPED, S_RODENT,
  820. X+ S_SPIDER, S_TRAPPER, S_UNICORN, S_VORTEX, S_WORM, S_XAN, S_YLIGHT, S_ZRUTY,
  821. X+ S_APE, S_BAT, S_CENTAUR, S_DRAGON, S_ELEMENTAL, S_FUNGUS, S_GNOME, S_GIANT,
  822. X+ S_STALKER, S_JABBERWOCK,
  823. X+ #ifdef KOPS
  824. X+ S_KOP,
  825. X+ #endif
  826. X+ S_LICH, S_MUMMY, S_NAGA, S_OGRE, S_PUDDING, S_QUANTMECH, S_RUSTMONST, S_SNAKE,
  827. X+ S_TROLL, S_UMBER, S_VAMPIRE, S_WRAITH, S_XORN, S_YETI, S_ZOMBIE,
  828. X+ #ifdef GOLEMS
  829. X+ S_GOLEM,
  830. X+ #endif
  831. X+ S_DEMON, S_EEL, S_LIZARD,
  832. X+ #ifdef WORM
  833. X+ S_WORM_TAIL,
  834. X+ #endif
  835. X+ 0 };
  836. X+ 
  837. X+ const char objsyms[] = { WEAPON_SYM, ARMOR_SYM, POTION_SYM, SCROLL_SYM,
  838. X+ WAND_SYM,
  839. X+ #ifdef SPELLS
  840. X+ SPBOOK_SYM,
  841. X+ #endif
  842. X+ RING_SYM, AMULET_SYM, FOOD_SYM, TOOL_SYM, GEM_SYM, GOLD_SYM,
  843. X+ ROCK_SYM, BALL_SYM, CHAIN_SYM, 0 };
  844. X+ 
  845. X+ const char *monexplain[] = {
  846. X+ "human", "ghost", "ant or other insect", "blob", "cockatrice",
  847. X+ "dog or other canine", "eye or sphere", "feline", "gremlin", "humanoid",
  848. X+ "imp or minor demon", "jelly", "kobold", "leprechaun", "mimic",
  849. X+ "nymph", "orc", "piercer", "quadruped", "rodent",
  850. X+ "spider", "trapper or lurker above", "unicorn", "vortex", "worm",
  851. X+ "xan or other mythical/fantastic insect", "yellow light", "zruty",
  852. X+ "ape", "bat", "centaur", "dragon", "elemental",
  853. X+ "fungus or mold", "gnome", "giant humanoid", "invisible stalker", "jabberwock",
  854. X+ #ifdef KOPS
  855. X+ "Keystone Kop",
  856. X+ #endif
  857. X+ "lich", "mummy", "naga", "ogre", "pudding or ooze",
  858. X+ "quantum mechanic", "rust monster", "snake", "troll", "umber hulk",
  859. X+ "vampire", "wraith", "xorn", "yeti", "zombie",
  860. X+ #ifdef GOLEMS
  861. X+ "golem",
  862. X+ #endif
  863. X+ "demon",  "sea monster", "lizard",
  864. X+ #ifdef WORM
  865. X+ "long worm tail",
  866. X+ #endif
  867. X+ };
  868. X+ 
  869. X+ const char *objexplain[] = {
  870. X+ "weapon", "suit or piece of armor", "potion", "scroll", "wand",
  871. X+ #ifdef SPELLS
  872. X+ "spell book",
  873. X+ #endif
  874. X+ "ring", "amulet", "piece of food", "useful item (pick-axe, key, lamp...)",
  875. X+ "gem or rock", "pile of gold", "boulder or statue", "iron ball", "iron chain"
  876. X+ };
  877. X*** src/Old/demon.c    Mon Feb 19 17:56:35 1990
  878. X--- src/demon.c    Wed Jan 31 19:34:15 1990
  879. X***************
  880. X*** 9,15 ****
  881. X      register struct permonst *ptr;
  882. X  {
  883. X  #ifdef INFERNO
  884. X!     register int dtype, cnt = 0;
  885. X  
  886. X      if(is_dprince(ptr) || (ptr == &mons[PM_WIZARD_OF_YENDOR])) {
  887. X  
  888. X--- 9,15 ----
  889. X      register struct permonst *ptr;
  890. X  {
  891. X  #ifdef INFERNO
  892. X!     register int dtype = 0, cnt = 0;
  893. X  
  894. X      if(is_dprince(ptr) || (ptr == &mons[PM_WIZARD_OF_YENDOR])) {
  895. X  
  896. X***************
  897. X*** 44,53 ****
  898. X  #define    Athome    (Inhell && !mtmp->cham)
  899. X  
  900. X  int
  901. X! demon_talk(mtmp)        /* returns 1 if he won't attack. */
  902. X  register struct monst *mtmp;
  903. X  {
  904. X-     char    *x_monnam(), *Xmonnam();
  905. X      long    demand, offer;
  906. X  
  907. X  #ifdef NAMED_ITEMS
  908. X--- 44,52 ----
  909. X  #define    Athome    (Inhell && !mtmp->cham)
  910. X  
  911. X  int
  912. X! demon_talk(mtmp)        /* returns 1 if it won't attack. */
  913. X  register struct monst *mtmp;
  914. X  {
  915. X      long    demand, offer;
  916. X  
  917. X  #ifdef NAMED_ITEMS
  918. X***************
  919. X*** 58,70 ****
  920. X      }
  921. X  #endif /* NAMED_ITEMS */
  922. X  
  923. X-     if(is_ndemon(mtmp->data)) {  /* not for regular '&'s */
  924. X- 
  925. X-         pline("%s mutters something about awful working conditions.",
  926. X-           Xmonnam(mtmp));
  927. X-         return(0);
  928. X-     }
  929. X- 
  930. X      /* Slight advantage given. */
  931. X      if(is_dprince(mtmp->data) && mtmp->minvis) {
  932. X          mtmp->minvis = 0;
  933. X--- 57,62 ----
  934. X***************
  935. X*** 73,79 ****
  936. X      }
  937. X      if(u.usym == S_DEMON) {    /* Won't blackmail their own. */
  938. X  
  939. X!         pline("%s says, \"Good hunting %s.\" and vanishes.",
  940. X            Xmonnam(mtmp), flags.female ? "Sister" : "Brother");
  941. X          rloc(mtmp);
  942. X          return(1);
  943. X--- 65,71 ----
  944. X      }
  945. X      if(u.usym == S_DEMON) {    /* Won't blackmail their own. */
  946. X  
  947. X!         pline("%s says, \"Good hunting, %s.\" and vanishes.",
  948. X            Xmonnam(mtmp), flags.female ? "Sister" : "Brother");
  949. X          rloc(mtmp);
  950. X          return(1);
  951. X***************
  952. X*** 87,93 ****
  953. X            Xmonnam(mtmp), demand, plur(demand));
  954. X  
  955. X          if((offer = bribe(mtmp)) >= demand) {
  956. X!         pline("%s vanishes laughing about cowardly mortals.",
  957. X                Xmonnam(mtmp));
  958. X          } else {
  959. X          if((long)rnd(40) > (demand - offer)) {
  960. X--- 79,85 ----
  961. X            Xmonnam(mtmp), demand, plur(demand));
  962. X  
  963. X          if((offer = bribe(mtmp)) >= demand) {
  964. X!         pline("%s vanishes, laughing about cowardly mortals.",
  965. X                Xmonnam(mtmp));
  966. X          } else {
  967. X          if((long)rnd(40) > (demand - offer)) {
  968. X*** src/Old/do.c    Mon Feb 19 17:56:55 1990
  969. X--- src/do.c    Mon Feb 19 10:18:11 1990
  970. X***************
  971. X*** 1,4 ****
  972. X! /*    SCCS Id: @(#)do.c    3.0    89/11/15
  973. X  /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
  974. X  /* NetHack may be freely redistributed.  See license for details. */
  975. X  
  976. X--- 1,4 ----
  977. X! /*    SCCS Id: @(#)do.c    3.0    89/11/20
  978. X  /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
  979. X  /* NetHack may be freely redistributed.  See license for details. */
  980. X  
  981. X***************
  982. X*** 6,21 ****
  983. X  
  984. X  #include "hack.h"
  985. X  
  986. X! #if defined(DGK) && !defined(OLD_TOS)
  987. X  extern struct finfo fileinfo[];
  988. X  #else
  989. X  extern boolean level_exists[];
  990. X  #endif
  991. X  
  992. X  #ifndef OVERLAY
  993. X  static int FDECL(drop, (struct obj *));
  994. X  #endif
  995. X  
  996. X  static const char drop_types[] = { '0', GOLD_SYM, '#', 0 };
  997. X  
  998. X  int
  999. X--- 6,32 ----
  1000. X  
  1001. X  #include "hack.h"
  1002. X  
  1003. X! #if defined(DGK)
  1004. X  extern struct finfo fileinfo[];
  1005. X  #else
  1006. X  extern boolean level_exists[];
  1007. X  #endif
  1008. X  
  1009. X+ #ifdef SINKS
  1010. X+ static void FDECL(trycall, (struct obj *));
  1011. X+ static void FDECL(dosinkring, (struct obj *));
  1012. X+ #endif
  1013. X  #ifndef OVERLAY
  1014. X  static int FDECL(drop, (struct obj *));
  1015. X  #endif
  1016. X+ static void NDECL(litter);
  1017. X+ #ifndef OVERLAY
  1018. X+ static int NDECL(wipeoff);
  1019. X+ #endif
  1020. X+ boolean NDECL(drag_down);
  1021. X  
  1022. X+ #ifdef OVLB
  1023. X+ 
  1024. X  static const char drop_types[] = { '0', GOLD_SYM, '#', 0 };
  1025. X  
  1026. X  int
  1027. X***************
  1028. X*** 23,28 ****
  1029. X--- 34,42 ----
  1030. X      return(drop(getobj(drop_types, "drop")));
  1031. X  }
  1032. X  
  1033. X+ #endif /* OVLB */
  1034. X+ #ifdef OVL0
  1035. X+ 
  1036. X  /* Used for objects which sometimes do special things when dropped; must be
  1037. X   * called with the object not in any chain.  Returns 1 if the object is
  1038. X   * gone.
  1039. X***************
  1040. X*** 58,64 ****
  1041. X          if (Blind) You("hear the boulder roll.");
  1042. X          else pline("The boulder %sfills a %s.",
  1043. X              t->tseen ? "" : "triggers and ",
  1044. X!             t->ttyp == TRAPDOOR ? "trapdoor" : "pit");
  1045. X          deltrap(t);
  1046. X          if (u.utrap && x==u.ux && y==u.uy) {
  1047. X              u.utrap = 0;
  1048. X--- 72,78 ----
  1049. X          if (Blind) You("hear the boulder roll.");
  1050. X          else pline("The boulder %sfills a %s.",
  1051. X              t->tseen ? "" : "triggers and ",
  1052. X!             t->ttyp == TRAPDOOR ? "trap door" : "pit");
  1053. X          deltrap(t);
  1054. X          if (u.utrap && x==u.ux && y==u.uy) {
  1055. X              u.utrap = 0;
  1056. X***************
  1057. X*** 66,72 ****
  1058. X              if (!passes_walls(uasmon)) {
  1059. X  #endif
  1060. X              pline("Unfortunately, you were still in it.");
  1061. X!             losehp(rnd(15), "burial beneath a boulder");
  1062. X  #ifdef POLYSELF
  1063. X              }
  1064. X  #endif
  1065. X--- 80,88 ----
  1066. X              if (!passes_walls(uasmon)) {
  1067. X  #endif
  1068. X              pline("Unfortunately, you were still in it.");
  1069. X!             losehp(rnd(15),
  1070. X!               self_pronoun("dropped a boulder onto %sself","him"),
  1071. X!               NO_KILLER_PREFIX);
  1072. X  #ifdef POLYSELF
  1073. X              }
  1074. X  #endif
  1075. X***************
  1076. X*** 81,86 ****
  1077. X--- 97,105 ----
  1078. X      return FALSE;
  1079. X  }
  1080. X  
  1081. X+ #endif /* OVL0 */
  1082. X+ #ifdef OVLB
  1083. X+ 
  1084. X  #ifdef ALTARS
  1085. X  void
  1086. X  doaltarobj(obj)  /* obj is an object dropped on an altar */
  1087. X***************
  1088. X*** 241,247 ****
  1089. X  boolean
  1090. X  canletgo(obj,word)
  1091. X  register struct obj *obj;
  1092. X! register char *word;
  1093. X  {
  1094. X      if(obj->owornmask & (W_ARMOR | W_RING | W_AMUL | W_TOOL)){
  1095. X             if (*word)
  1096. X--- 260,266 ----
  1097. X  boolean
  1098. X  canletgo(obj,word)
  1099. X  register struct obj *obj;
  1100. X! register const char *word;
  1101. X  {
  1102. X      if(obj->owornmask & (W_ARMOR | W_RING | W_AMUL | W_TOOL)){
  1103. X             if (*word)
  1104. X***************
  1105. X*** 249,259 ****
  1106. X          return(FALSE);
  1107. X      }
  1108. X      if (obj->otyp == LOADSTONE && obj->cursed) {
  1109. X-         obj->bknown = 1;
  1110. X          if (*word)
  1111. X              pline("For some reason, you cannot %s the stone%s!",
  1112. X                  word,
  1113. X                        plur((long)obj->quan));
  1114. X          return(FALSE);
  1115. X      }
  1116. X  #ifdef WALKIES
  1117. X--- 268,289 ----
  1118. X          return(FALSE);
  1119. X      }
  1120. X      if (obj->otyp == LOADSTONE && obj->cursed) {
  1121. X          if (*word)
  1122. X              pline("For some reason, you cannot %s the stone%s!",
  1123. X                  word,
  1124. X                        plur((long)obj->quan));
  1125. X+         /* Kludge -- see invent.c */
  1126. X+         if (obj->corpsenm) {
  1127. X+             struct obj *otmp;
  1128. X+ 
  1129. X+             otmp = obj;
  1130. X+             obj = obj->nobj;
  1131. X+             obj->quan += otmp->quan;
  1132. X+             obj->owt = weight(obj);
  1133. X+             freeinv(otmp);
  1134. X+             obfree(otmp, obj);
  1135. X+         }
  1136. X+         obj->bknown = 1;
  1137. X          return(FALSE);
  1138. X      }
  1139. X  #ifdef WALKIES
  1140. X***************
  1141. X*** 400,406 ****
  1142. X  #ifdef STRONGHOLD
  1143. X              levl[u.ux][u.uy].typ == LADDER ? "ladder" :
  1144. X  #endif
  1145. X!             "trapdoor");
  1146. X          return(0);
  1147. X      }
  1148. X  
  1149. X--- 430,436 ----
  1150. X  #ifdef STRONGHOLD
  1151. X              levl[u.ux][u.uy].typ == LADDER ? "ladder" :
  1152. X  #endif
  1153. X!             "trap door");
  1154. X          return(0);
  1155. X      }
  1156. X  
  1157. X***************
  1158. X*** 415,421 ****
  1159. X          if (levl[u.ux][u.uy].typ == LADDER) at_ladder = TRUE;
  1160. X  #endif
  1161. X          if (trap)
  1162. X!             pline("You jump into the trapdoor...");
  1163. X          goto_level(dlevel+1, !trap, TRUE);
  1164. X  #ifdef STRONGHOLD
  1165. X          at_ladder = FALSE;
  1166. X--- 445,456 ----
  1167. X          if (levl[u.ux][u.uy].typ == LADDER) at_ladder = TRUE;
  1168. X  #endif
  1169. X          if (trap)
  1170. X! #ifdef POLYSELF
  1171. X!             You("%s into the trap door.",
  1172. X!                 locomotion(uasmon, "jump"));
  1173. X! #else
  1174. X!             You("jump into the trap door.");
  1175. X! #endif
  1176. X          goto_level(dlevel+1, !trap, TRUE);
  1177. X  #ifdef STRONGHOLD
  1178. X          at_ladder = FALSE;
  1179. X***************
  1180. X*** 461,469 ****
  1181. X--- 496,512 ----
  1182. X  
  1183. X  #ifdef ENDGAME
  1184. X      if (dlevel == 1) {
  1185. X+ #ifdef MACOS
  1186. X+         if(!flags.silent) SysBeep(20);
  1187. X+         if(UseMacAlertText(128,
  1188. X+             "Beware, there will be no return!  Still climb?") != 1) {
  1189. X+             return 0;
  1190. X+         }
  1191. X+ #else
  1192. X          pline("Beware, there will be no return!  Still climb? ");
  1193. X          if (yn() != 'y') return(0);
  1194. X          else more();
  1195. X+ #endif /* MACOS */
  1196. X      }
  1197. X  #endif
  1198. X  #ifdef WALKIES
  1199. X***************
  1200. X*** 537,554 ****
  1201. X      if(forward) {
  1202. X          if(rn2(6)) {
  1203. X              You("get dragged downstairs by the iron ball.");
  1204. X!             losehp(rnd(6), "iron ball accident");
  1205. X              return(TRUE);
  1206. X          }
  1207. X      } else {
  1208. X          if(rn2(2)) {
  1209. X              pline("The iron ball smacks into you!");
  1210. X!             losehp(rnd(20), "iron ball collision");
  1211. X              dragchance -= 2;
  1212. X          } 
  1213. X          if(dragchance >= rnd(6)) {
  1214. X              You("get dragged downstairs by the iron ball.");
  1215. X!             losehp(rnd(3), "iron ball accident");
  1216. X              return(TRUE);
  1217. X          }
  1218. X      }
  1219. X--- 580,599 ----
  1220. X      if(forward) {
  1221. X          if(rn2(6)) {
  1222. X              You("get dragged downstairs by the iron ball.");
  1223. X!             losehp(rnd(6), "dragged downstairs by an iron ball",
  1224. X!                 NO_KILLER_PREFIX);
  1225. X              return(TRUE);
  1226. X          }
  1227. X      } else {
  1228. X          if(rn2(2)) {
  1229. X              pline("The iron ball smacks into you!");
  1230. X!             losehp(rnd(20), "iron ball collision", KILLED_BY_AN);
  1231. X              dragchance -= 2;
  1232. X          } 
  1233. X          if(dragchance >= rnd(6)) {
  1234. X              You("get dragged downstairs by the iron ball.");
  1235. X!             losehp(rnd(3), "dragged downstairs by an iron ball",
  1236. X!                 NO_KILLER_PREFIX);
  1237. X              return(TRUE);
  1238. X          }
  1239. X      }
  1240. X***************
  1241. X*** 555,560 ****
  1242. X--- 600,607 ----
  1243. X      return(FALSE);
  1244. X  }
  1245. X  
  1246. X+ int save_dlevel = 0;
  1247. X+ 
  1248. X  void
  1249. X  goto_level(newlevel, at_stairs, falling)
  1250. X  register int newlevel;
  1251. X***************
  1252. X*** 613,626 ****
  1253. X          if(Fire_resistance) {
  1254. X          pline("But the fire doesn't seem to harm you.");
  1255. X          } else {
  1256. X!         int save_dlevel = dlevel;
  1257. X! 
  1258. X          You("burn to a crisp.");
  1259. X          You("die...");
  1260. X          dlevel = maxdlevel = newlevel;
  1261. X          killer = "visit to hell";
  1262. X          done(BURNING);
  1263. X          dlevel = newlevel = save_dlevel; /* in case they survive */
  1264. X          }
  1265. X      }
  1266. X  
  1267. X--- 660,674 ----
  1268. X          if(Fire_resistance) {
  1269. X          pline("But the fire doesn't seem to harm you.");
  1270. X          } else {
  1271. X!         save_dlevel = dlevel;
  1272. X          You("burn to a crisp.");
  1273. X          You("die...");
  1274. X          dlevel = maxdlevel = newlevel;
  1275. X+         killer_format = KILLED_BY_AN;
  1276. X          killer = "visit to hell";
  1277. X          done(BURNING);
  1278. X          dlevel = newlevel = save_dlevel; /* in case they survive */
  1279. X+         save_dlevel = 0;
  1280. X          }
  1281. X      }
  1282. X  
  1283. X***************
  1284. X*** 645,651 ****
  1285. X          if (FSOpen(fileName, t->system.sysVRefNum, &refNum)) {
  1286. X                  if (er = Create(&fileName,t->system.sysVRefNum,
  1287. X                              CREATOR,LEVEL_TYPE))
  1288. X!                     SysBeep(1);
  1289. X          } else {
  1290. X              (void)SetEOF(refNum,0L);
  1291. X              (void)FSClose(refNum);
  1292. X--- 693,699 ----
  1293. X          if (FSOpen(fileName, t->system.sysVRefNum, &refNum)) {
  1294. X                  if (er = Create(&fileName,t->system.sysVRefNum,
  1295. X                              CREATOR,LEVEL_TYPE))
  1296. X!                     SysBeep(20);
  1297. X          } else {
  1298. X              (void)SetEOF(refNum,0L);
  1299. X              (void)FSClose(refNum);
  1300. X***************
  1301. X*** 694,701 ****
  1302. X      if(u.uswallow)                /* idem */
  1303. X          u.uswldtim = u.uswallow = 0;
  1304. X      flags.nscrinh = 1;
  1305. X!     u.ux = FAR;                /* hack */
  1306. X!     (void) inshop();            /* probably was a trapdoor */
  1307. X  
  1308. X  #ifdef DGK
  1309. X  # ifdef ZEROCOMP
  1310. X--- 742,749 ----
  1311. X      if(u.uswallow)                /* idem */
  1312. X          u.uswldtim = u.uswallow = 0;
  1313. X      flags.nscrinh = 1;
  1314. X!     u.ux = u.ux0 = FAR;                /* hack */
  1315. X!     (void) inshop();            /* probably was a trap door */
  1316. X  
  1317. X  #ifdef DGK
  1318. X  # ifdef ZEROCOMP
  1319. X***************
  1320. X*** 733,739 ****
  1321. X  # ifdef ENDGAME
  1322. X         dlevel == ENDLEVEL ||
  1323. X  # endif
  1324. X! #if defined(DGK) && !defined(OLD_TOS)
  1325. X      /* If the level has no .where yet, it hasn't been made */
  1326. X         !fileinfo[dlevel].where)
  1327. X  #else
  1328. X--- 781,787 ----
  1329. X  # ifdef ENDGAME
  1330. X         dlevel == ENDLEVEL ||
  1331. X  # endif
  1332. X! #if defined(DGK)
  1333. X      /* If the level has no .where yet, it hasn't been made */
  1334. X         !fileinfo[dlevel].where)
  1335. X  #else
  1336. X***************
  1337. X*** 741,747 ****
  1338. X  #endif
  1339. X          mklev();
  1340. X      else {
  1341. X! #if defined(DGK) && !defined(OLD_TOS)
  1342. X          /* If not currently accessible, swap it in. */
  1343. X          if (fileinfo[dlevel].where != ACTIVE)
  1344. X              swapin_file(dlevel);
  1345. X--- 789,795 ----
  1346. X  #endif
  1347. X          mklev();
  1348. X      else {
  1349. X! #if defined(DGK)
  1350. X          /* If not currently accessible, swap it in. */
  1351. X          if (fileinfo[dlevel].where != ACTIVE)
  1352. X              swapin_file(dlevel);
  1353. X***************
  1354. X*** 762,767 ****
  1355. X--- 810,825 ----
  1356. X          (void) close(fd);
  1357. X      }
  1358. X  
  1359. X+ #ifdef MACOS
  1360. X+     {
  1361. X+         OSErr    er;
  1362. X+         struct term_info    *t;
  1363. X+         extern WindowPtr    HackWindow;
  1364. X+         
  1365. X+         t = (term_info *)GetWRefCon(HackWindow);
  1366. X+         SetVol(0L,t->system.sysVRefNum);
  1367. X+     }
  1368. X+ #endif
  1369. X  #ifdef ENDGAME
  1370. X      if(dlevel != ENDLEVEL)
  1371. X  #endif
  1372. X***************
  1373. X*** 820,830 ****
  1374. X                  }
  1375. X                  placebc(1);
  1376. X              } 
  1377. X!             losehp(rnd(3), "fall");
  1378. X              selftouch("Falling, you");
  1379. X          }
  1380. X          }
  1381. X!     } else {    /* trapdoor or level_tele */
  1382. X          register int tryct = 0;
  1383. X          do {
  1384. X  #ifdef STRONGHOLD
  1385. X--- 878,888 ----
  1386. X                  }
  1387. X                  placebc(1);
  1388. X              } 
  1389. X!             losehp(rnd(3), "falling downstairs", KILLED_BY);
  1390. X              selftouch("Falling, you");
  1391. X          }
  1392. X          }
  1393. X!     } else {    /* trap door or level_tele */
  1394. X          register int tryct = 0;
  1395. X          do {
  1396. X  #ifdef STRONGHOLD
  1397. X***************
  1398. X*** 865,871 ****
  1399. X                      body_part(HEAD));
  1400. X                  if (uarmh)
  1401. X                      Your("helmet doesn't help too much...");
  1402. X!                 losehp(rnd(25), "iron ball");
  1403. X              }
  1404. X          }
  1405. X          placebc(1);
  1406. X--- 923,931 ----
  1407. X                      body_part(HEAD));
  1408. X                  if (uarmh)
  1409. X                      Your("helmet doesn't help too much...");
  1410. X!                 losehp(rnd(25),
  1411. X!                     "Crunched in the head by an iron ball",
  1412. X!                     NO_KILLER_PREFIX);
  1413. X              }
  1414. X          }
  1415. X          placebc(1);
  1416. X***************
  1417. X*** 878,883 ****
  1418. X--- 938,947 ----
  1419. X  
  1420. X      losedogs();
  1421. X      if(MON_AT(u.ux, u.uy)) mnexto(m_at(u.ux, u.uy));
  1422. X+     if(MON_AT(u.ux, u.uy)) {
  1423. X+         impossible("mnexto failed (do.c)?");
  1424. X+         rloc(m_at(u.ux, u.uy));
  1425. X+     }
  1426. X      flags.nscrinh = 0;
  1427. X      setsee();
  1428. X      seeobjs();    /* make old cadavers disappear - riv05!a3 */
  1429. X***************
  1430. X*** 949,963 ****
  1431. X  struct obj *
  1432. X  splitobj(obj, num) register struct obj *obj; register int num; {
  1433. X  register struct obj *otmp;
  1434. X!     otmp = newobj(0);
  1435. X      *otmp = *obj;        /* copies whole structure */
  1436. X      otmp->o_id = flags.ident++;
  1437. X-     otmp->onamelth = 0;
  1438. X      obj->quan = num;
  1439. X      obj->owt = weight(obj);
  1440. X      otmp->quan -= num;
  1441. X      otmp->owt = weight(otmp);    /* -= obj->owt ? */
  1442. X      obj->nobj = obj->nexthere = otmp;
  1443. X      if(obj->unpaid) splitbill(obj,otmp);
  1444. X      return(otmp);
  1445. X  }
  1446. X--- 1013,1028 ----
  1447. X  struct obj *
  1448. X  splitobj(obj, num) register struct obj *obj; register int num; {
  1449. X  register struct obj *otmp;
  1450. X!     otmp = newobj(obj->onamelth);
  1451. X      *otmp = *obj;        /* copies whole structure */
  1452. X      otmp->o_id = flags.ident++;
  1453. X      obj->quan = num;
  1454. X      obj->owt = weight(obj);
  1455. X      otmp->quan -= num;
  1456. X      otmp->owt = weight(otmp);    /* -= obj->owt ? */
  1457. X      obj->nobj = obj->nexthere = otmp;
  1458. X+     if (obj->onamelth)
  1459. X+         (void)strncpy(ONAME(otmp), ONAME(obj), (int)obj->onamelth);
  1460. X      if(obj->unpaid) splitbill(obj,otmp);
  1461. X      return(otmp);
  1462. X  }
  1463. X***************
  1464. X*** 994,996 ****
  1465. X--- 1059,1063 ----
  1466. X          Wounded_legs = 0;
  1467. X      }
  1468. X  }
  1469. X+ 
  1470. X+ #endif /* OVLB */
  1471. X*** src/Old/do_name.c    Mon Feb 19 17:57:44 1990
  1472. X--- src/do_name.c    Mon Feb 19 14:45:58 1990
  1473. X***************
  1474. X*** 4,9 ****
  1475. X--- 4,18 ----
  1476. X  
  1477. X  #include "hack.h"
  1478. X  
  1479. X+ #ifdef NAMED_ITEMS
  1480. X+ # include <ctype.h>
  1481. X+ #endif
  1482. X+ 
  1483. X+ static char *FDECL(visctrl, (CHAR_P));
  1484. X+ static void FDECL(do_oname, (struct obj *));
  1485. X+ 
  1486. X+ #ifdef OVLB
  1487. X+ 
  1488. X  static
  1489. X  char *
  1490. X  visctrl(c)
  1491. X***************
  1492. X*** 29,39 ****
  1493. X  void
  1494. X  getpos(cc,force,goal)
  1495. X  coord    *cc;
  1496. X! int force; char *goal;
  1497. X  {
  1498. X      register int cx, cy, i, c;
  1499. X      const char *sdp = flags.num_pad ? ndir : sdir;
  1500. X      if(flags.verbose) pline("(For instructions type a ?)");
  1501. X      cx = cc->x;
  1502. X      cy = cc->y;
  1503. X  #ifdef CLIPPING
  1504. X--- 38,64 ----
  1505. X  void
  1506. X  getpos(cc,force,goal)
  1507. X  coord    *cc;
  1508. X! int force;
  1509. X! const char *goal;
  1510. X  {
  1511. X      register int cx, cy, i, c;
  1512. X      const char *sdp = flags.num_pad ? ndir : sdir;
  1513. X+ #ifdef MACOS
  1514. X+     extern short    macflags;
  1515. X+     Boolean    fUpdateFlagOn;
  1516. X+     long    ticks;
  1517. X+ #endif
  1518. X+ 
  1519. X      if(flags.verbose) pline("(For instructions type a ?)");
  1520. X+ #ifdef MACOS    
  1521. X+     if ((macflags & fDoUpdate) && (macflags & fDoNonKeyEvt)) {
  1522. X+         fUpdateFlagOn = true;
  1523. X+     } else {
  1524. X+         fUpdateFlagOn = false;
  1525. X+         macflags |= (fDoUpdate | fDoNonKeyEvt);
  1526. X+     }
  1527. X+     macflags |= fMoveWRTMouse;
  1528. X+ #endif
  1529. X      cx = cc->x;
  1530. X      cy = cc->y;
  1531. X  #ifdef CLIPPING
  1532. X***************
  1533. X*** 63,68 ****
  1534. X--- 88,98 ----
  1535. X                              "use hjkl or ." :
  1536. X                      "aborted");
  1537. X              if(force) goto nxtc;
  1538. X+ #ifdef MACOS
  1539. X+             macflags &= ~fMoveWRTMouse;
  1540. X+             if (!fUpdateFlagOn)
  1541. X+                 macflags &= ~(fDoUpdate | fDoNonKeyEvt);
  1542. X+ #endif
  1543. X              cc->x = -1;
  1544. X              cc->y = 0;
  1545. X              return;
  1546. X***************
  1547. X*** 75,91 ****
  1548. X          curs(cx,cy+2);
  1549. X  #endif
  1550. X      }
  1551. X      cc->x = cx;
  1552. X      cc->y = cy;
  1553. X      return;
  1554. X  }
  1555. X  
  1556. X  int
  1557. X  do_mname(){
  1558. X      char buf[BUFSZ];
  1559. X      coord cc;
  1560. X!     register int cx,cy,lth,i;
  1561. X!     register struct monst *mtmp, *mtmp2;
  1562. X      register char *curr;
  1563. X      boolean blank;
  1564. X  
  1565. X--- 105,151 ----
  1566. X          curs(cx,cy+2);
  1567. X  #endif
  1568. X      }
  1569. X+ #ifdef MACOS
  1570. X+     macflags &= ~fMoveWRTMouse;
  1571. X+     if (!fUpdateFlagOn)
  1572. X+         macflags &= ~(fDoUpdate | fDoNonKeyEvt);
  1573. X+ #endif
  1574. X      cc->x = cx;
  1575. X      cc->y = cy;
  1576. X      return;
  1577. X  }
  1578. X  
  1579. X+ struct monst *
  1580. X+ christen_monst(mtmp, name)
  1581. X+ struct monst *mtmp;
  1582. X+ const char *name;
  1583. X+ {
  1584. X+     register int lth,i;
  1585. X+     register struct monst *mtmp2;
  1586. X+ 
  1587. X+     /* dogname and catname are 63-character arrays; the generic naming
  1588. X+      * function do_mname() below also cut names off at 63 characters */
  1589. X+     lth = strlen(name)+1;
  1590. X+     if(lth > 63){
  1591. X+         lth = 63;
  1592. X+     }
  1593. X+     mtmp2 = newmonst(mtmp->mxlth + lth);
  1594. X+     *mtmp2 = *mtmp;
  1595. X+     for(i=0; i<mtmp->mxlth; i++)
  1596. X+         ((char *) mtmp2->mextra)[i] = ((char *) mtmp->mextra)[i];
  1597. X+     mtmp2->mnamelth = lth;
  1598. X+     (void)strncpy(NAME(mtmp2), name, lth);
  1599. X+     NAME(mtmp2)[lth-1] = 0;
  1600. X+     replmon(mtmp,mtmp2);
  1601. X+     return(mtmp2);
  1602. X+ }
  1603. X+ 
  1604. X  int
  1605. X  do_mname(){
  1606. X      char buf[BUFSZ];
  1607. X      coord cc;
  1608. X!     register int cx,cy;
  1609. X!     register struct monst *mtmp;
  1610. X      register char *curr;
  1611. X      boolean blank;
  1612. X  
  1613. X***************
  1614. X*** 127,144 ****
  1615. X           }
  1616. X           return(0);
  1617. X       }
  1618. X!     lth = strlen(buf)+1;
  1619. X!     if(lth > 63){
  1620. X!         buf[62] = 0;
  1621. X!         lth = 63;
  1622. X!     }
  1623. X!     mtmp2 = newmonst(mtmp->mxlth + lth);
  1624. X!     *mtmp2 = *mtmp;
  1625. X!     for(i=0; i<mtmp->mxlth; i++)
  1626. X!         ((char *) mtmp2->mextra)[i] = ((char *) mtmp->mextra)[i];
  1627. X!     mtmp2->mnamelth = lth;
  1628. X!     Strcpy(NAME(mtmp2), buf);
  1629. X!     replmon(mtmp,mtmp2);
  1630. X      return(0);
  1631. X  }
  1632. X  
  1633. X--- 187,193 ----
  1634. X           }
  1635. X           return(0);
  1636. X       }
  1637. X!     (void) christen_monst(mtmp, buf);
  1638. X      return(0);
  1639. X  }
  1640. X  
  1641. X***************
  1642. X*** 166,173 ****
  1643. X      if(blank) *buf = '\0';
  1644. X  
  1645. X  #ifdef NAMED_ITEMS
  1646. X!     if(is_artifact(obj) || restr_name(obj, buf))
  1647. X!         pline("Somehow you can't seem to engrave that word.");
  1648. X      else
  1649. X  #endif
  1650. X          (void)oname(obj, buf, 1);
  1651. X--- 215,234 ----
  1652. X      if(blank) *buf = '\0';
  1653. X  
  1654. X  #ifdef NAMED_ITEMS
  1655. X!     if(is_artifact(obj))
  1656. X!         pline("The artifact seems to resist the attempt.");
  1657. X!     else if (restr_name(obj, buf) || exist_artifact(obj, buf)) {
  1658. X!         int n = rn2(strlen(buf));
  1659. X!         char c;
  1660. X! 
  1661. X!         while (tolower(buf[n]) == (c = 'a' + rn2('z'-'a')));
  1662. X!         if (isupper(buf[n])) buf[n] = toupper(c);
  1663. X!         else buf[n] = c;
  1664. X!         pline("While engraving your hand slips.");
  1665. X!         more();
  1666. X!         You("engrave: \"%s\".",buf);
  1667. X!         (void)oname(obj, buf, 1);
  1668. X!     }
  1669. X      else
  1670. X  #endif
  1671. X          (void)oname(obj, buf, 1);
  1672. X***************
  1673. X*** 176,182 ****
  1674. X  struct obj *
  1675. X  oname(obj, buf, ininv)
  1676. X  register struct obj *obj;
  1677. X! char    *buf;
  1678. X  register int ininv;
  1679. X  {
  1680. X      register struct obj *otmp, *otmp2, *contents;
  1681. X--- 237,243 ----
  1682. X  struct obj *
  1683. X  oname(obj, buf, ininv)
  1684. X  register struct obj *obj;
  1685. X! const char    *buf;
  1686. X  register int ininv;
  1687. X  {
  1688. X      register struct obj *otmp, *otmp2, *contents;
  1689. X***************
  1690. X*** 183,190 ****
  1691. X      register int    lth;
  1692. X  
  1693. X      lth = *buf ? strlen(buf)+1 : 0;
  1694. X      if(lth > 63){
  1695. X-         buf[62] = 0;
  1696. X          lth = 63;
  1697. X      }
  1698. X      otmp2 = newobj(lth);
  1699. X--- 244,257 ----
  1700. X      register int    lth;
  1701. X  
  1702. X      lth = *buf ? strlen(buf)+1 : 0;
  1703. X+ #ifdef NAMED_ITEMS
  1704. X+     /* if named artifact exists in the game, do not create another */
  1705. X+     if (exist_artifact(obj, buf))
  1706. X+         lth = 0;
  1707. X+     else
  1708. X+         artifact_exists(obj, buf, TRUE);
  1709. X+ #endif
  1710. X      if(lth > 63){
  1711. X          lth = 63;
  1712. X      }
  1713. X      otmp2 = newobj(lth);
  1714. X***************
  1715. X*** 198,205 ****
  1716. X       */
  1717. X      if (buf) (void)donull();
  1718. X  #endif
  1719. X!     if(lth) Strcpy(ONAME(otmp2), buf);
  1720. X! 
  1721. X      if (obj->owornmask) {
  1722. X          /* Note: dying by burning in Hell causes problems if you
  1723. X           * try doing this when owornmask isn't set.
  1724. X--- 265,274 ----
  1725. X       */
  1726. X      if (buf) (void)donull();
  1727. X  #endif
  1728. X!     if(lth) {
  1729. X!         (void)strncpy(ONAME(otmp2), buf, lth);
  1730. X!         ONAME(otmp2)[lth-1] = 0;
  1731. X!     }
  1732. X      if (obj->owornmask) {
  1733. X          /* Note: dying by burning in Hell causes problems if you
  1734. X           * try doing this when owornmask isn't set.
  1735. X***************
  1736. X*** 235,241 ****
  1737. X  #ifdef SPELLS
  1738. X      SPBOOK_SYM,
  1739. X  #endif
  1740. X!     ARMOR_SYM, 0 };
  1741. X  
  1742. X  int
  1743. X  ddocall()
  1744. X--- 304,310 ----
  1745. X  #ifdef SPELLS
  1746. X      SPBOOK_SYM,
  1747. X  #endif
  1748. X!     ARMOR_SYM, TOOL_SYM, 0 };
  1749. X  
  1750. X  int
  1751. X  ddocall()
  1752. X***************
  1753. X*** 296,302 ****
  1754. X  
  1755. X      /* clear old name */
  1756. X      str1 = &(objects[obj->otyp].oc_uname);
  1757. X!     if(*str1) free(*str1);
  1758. X  
  1759. X      /* uncalls item if all spaces */
  1760. X      for (str = buf, blank = 1; *str; blank = (*str++ == ' '));
  1761. X--- 365,371 ----
  1762. X  
  1763. X      /* clear old name */
  1764. X      str1 = &(objects[obj->otyp].oc_uname);
  1765. X!     if(*str1) free((genericptr_t)*str1);
  1766. X  
  1767. X      /* uncalls item if all spaces */
  1768. X      for (str = buf, blank = 1; *str; blank = (*str++ == ' '));
  1769. X***************
  1770. X*** 311,323 ****
  1771. X      *str1 = str;
  1772. X  }
  1773. X  
  1774. X! const char *ghostnames[] = {
  1775. X      /* these names should have length < PL_NSIZ */
  1776. X      /* Capitalize the names for aesthetics -dgk */
  1777. X      "Adri", "Andries", "Andreas", "Bert", "David", "Dirk", "Emile",
  1778. X      "Frans", "Fred", "Greg", "Hether", "Jay", "John", "Jon", "Karnov",
  1779. X      "Kay", "Kenny", "Kevin", "Maud", "Michiel", "Mike", "Peter", "Robert",
  1780. X!     "Ron", "Tom", "Wilmar", "Nick Danger", "Phoenix", "Miracleman",
  1781. X      "Stephan", "Lance Braccus", "Shadowhawk"
  1782. X  };
  1783. X  
  1784. X--- 380,395 ----
  1785. X      *str1 = str;
  1786. X  }
  1787. X  
  1788. X! #endif /*OVLB*/
  1789. X! #ifdef OVL0
  1790. X! 
  1791. X! static const char *ghostnames[] = {
  1792. X      /* these names should have length < PL_NSIZ */
  1793. X      /* Capitalize the names for aesthetics -dgk */
  1794. X      "Adri", "Andries", "Andreas", "Bert", "David", "Dirk", "Emile",
  1795. X      "Frans", "Fred", "Greg", "Hether", "Jay", "John", "Jon", "Karnov",
  1796. X      "Kay", "Kenny", "Kevin", "Maud", "Michiel", "Mike", "Peter", "Robert",
  1797. X!     "Ron", "Tom", "Wilmar", "Nick Danger", "Phoenix", "Havok",
  1798. X      "Stephan", "Lance Braccus", "Shadowhawk"
  1799. X  };
  1800. X  
  1801. X***************
  1802. X*** 361,367 ****
  1803. X          { register const char *gn = (const char *) mtmp->mextra;
  1804. X            if(!*gn) {        /* might also look in scorefile */
  1805. X              gn = ghostnames[rn2(SIZE(ghostnames))];
  1806. X!             Strcpy((char *) mtmp->mextra, !rn2(5) ? plname : gn);
  1807. X            }
  1808. X            Sprintf(buf, "%s's ghost", (char *) mtmp->mextra);
  1809. X          }
  1810. X--- 433,439 ----
  1811. X          { register const char *gn = (const char *) mtmp->mextra;
  1812. X            if(!*gn) {        /* might also look in scorefile */
  1813. X              gn = ghostnames[rn2(SIZE(ghostnames))];
  1814. X!             Strcpy((char *) mtmp->mextra, !rn2(5) ? (const char *)plname : gn);
  1815. X            }
  1816. X            Sprintf(buf, "%s's ghost", (char *) mtmp->mextra);
  1817. X          }
  1818. X***************
  1819. X*** 381,386 ****
  1820. X--- 453,461 ----
  1821. X      return(buf);
  1822. X  }
  1823. X  
  1824. X+ #endif /* OVL0 */
  1825. X+ #ifdef OVLB
  1826. X+ 
  1827. X  char *
  1828. X  lmonnam(mtmp)
  1829. X  register struct monst *mtmp;
  1830. X***************
  1831. X*** 388,393 ****
  1832. X--- 463,471 ----
  1833. X      return(x_monnam(mtmp, 1));
  1834. X  }
  1835. X  
  1836. X+ #endif /* OVLB */
  1837. X+ #ifdef OVL0
  1838. X+ 
  1839. X  char *
  1840. X  mon_nam(mtmp)
  1841. X  register struct monst *mtmp;
  1842. X***************
  1843. X*** 405,414 ****
  1844. X      return(bp);
  1845. X  }
  1846. X  
  1847. X  char *
  1848. X  a_monnam(mtmp,adj)
  1849. X  register struct monst *mtmp;
  1850. X! register char *adj;
  1851. X  {
  1852. X      register char *bp = mon_nam(mtmp);
  1853. X  #ifdef LINT    /* static char buf[BUFSZ]; */
  1854. X--- 483,495 ----
  1855. X      return(bp);
  1856. X  }
  1857. X  
  1858. X+ #endif /* OVL0 */
  1859. X+ #ifdef OVLB
  1860. X+ 
  1861. X  char *
  1862. X  a_monnam(mtmp,adj)
  1863. X  register struct monst *mtmp;
  1864. X! register const char *adj;
  1865. X  {
  1866. X      register char *bp = mon_nam(mtmp);
  1867. X  #ifdef LINT    /* static char buf[BUFSZ]; */
  1868. X***************
  1869. X*** 427,433 ****
  1870. X  char *
  1871. X  a2_monnam(mtmp,adj)
  1872. X  register struct monst *mtmp;
  1873. X! register char *adj;
  1874. X  {
  1875. X      register char *bp = mon_nam(mtmp);
  1876. X  #ifdef LINT    /* static char buf[BUFSZ]; */
  1877. X--- 508,514 ----
  1878. X  char *
  1879. X  a2_monnam(mtmp,adj)
  1880. X  register struct monst *mtmp;
  1881. X! register const char *adj;
  1882. X  {
  1883. X      register char *bp = mon_nam(mtmp);
  1884. X  #ifdef LINT    /* static char buf[BUFSZ]; */
  1885. X***************
  1886. X*** 446,452 ****
  1887. X  char *
  1888. X  Amonnam(mtmp, adj)
  1889. X  register struct monst *mtmp;
  1890. X! register char *adj;
  1891. X  {
  1892. X      register char *bp = a_monnam(mtmp,adj);
  1893. X  
  1894. X--- 527,533 ----
  1895. X  char *
  1896. X  Amonnam(mtmp, adj)
  1897. X  register struct monst *mtmp;
  1898. X! register const char *adj;
  1899. X  {
  1900. X      register char *bp = a_monnam(mtmp,adj);
  1901. X  
  1902. X***************
  1903. X*** 480,486 ****
  1904. X      return(bp);
  1905. X  }
  1906. X  
  1907. X! char *
  1908. X  rndmonnam() {  /* Random name of monster type, if hallucinating */
  1909. X      int name;
  1910. X  
  1911. X--- 561,567 ----
  1912. X      return(bp);
  1913. X  }
  1914. X  
  1915. X! const char *
  1916. X  rndmonnam() {  /* Random name of monster type, if hallucinating */
  1917. X      int name;
  1918. X  
  1919. X***************
  1920. X*** 491,498 ****
  1921. X      return(mons[name].mname);
  1922. X  }
  1923. X  
  1924. X! #ifdef REINCARNATION
  1925. X  char *
  1926. X  roguename() /* Name of a Rogue player */
  1927. X  {
  1928. X      char *i, *opts;
  1929. X--- 572,604 ----
  1930. X      return(mons[name].mname);
  1931. X  }
  1932. X  
  1933. X! const char *pronoun_pairs[][2] = {
  1934. X!     {"him", "her"}, {"Him", "Her"}, {"his", "her"}, {"His", "Her"},
  1935. X!     {"he", "she"}, {"He", "She"},
  1936. X!     {0, 0}
  1937. X! };
  1938. X! 
  1939. X  char *
  1940. X+ self_pronoun(str, pronoun)
  1941. X+ const char *str;
  1942. X+ const char *pronoun;
  1943. X+ {
  1944. X+     static char buf[BUFSZ];
  1945. X+     register int i;
  1946. X+ 
  1947. X+     for(i=0; pronoun_pairs[i][0]; i++) {
  1948. X+         if(!strncmp(pronoun, pronoun_pairs[i][0], 3)) {
  1949. X+             Sprintf(buf, str, pronoun_pairs[i][flags.female]);
  1950. X+             return buf;
  1951. X+         }
  1952. X+     }
  1953. X+     impossible("never heard of pronoun %s?", pronoun);
  1954. X+     Sprintf(buf, str, pronoun_pairs[i][0]);
  1955. X+     return buf;
  1956. X+ }
  1957. X+ 
  1958. X+ #ifdef REINCARNATION
  1959. X+ const char *
  1960. X  roguename() /* Name of a Rogue player */
  1961. X  {
  1962. X      char *i, *opts;
  1963. X***************
  1964. X*** 511,513 ****
  1965. X--- 617,620 ----
  1966. X  }
  1967. X  #endif
  1968. X  
  1969. X+ #endif /* OVLB */
  1970. X*** src/Old/do_wear.c    Mon Feb 19 17:58:13 1990
  1971. X--- src/do_wear.c    Wed Feb 14 17:54:32 1990
  1972. X***************
  1973. X*** 4,12 ****
  1974. X  
  1975. X  #include "hack.h"
  1976. X  
  1977. X  static int todelay;
  1978. X  
  1979. X! static long takeoff_mask = 0L, taking_off = 0L;
  1980. X  static const long takeoff_order[] = { WORN_BLINDF, 1L, /* weapon */
  1981. X      WORN_SHIELD, WORN_GLOVES, LEFT_RING, RIGHT_RING, WORN_CLOAK,
  1982. X      WORN_HELMET, WORN_AMUL, WORN_ARMOR,
  1983. X--- 4,23 ----
  1984. X  
  1985. X  #include "hack.h"
  1986. X  
  1987. X+ #ifdef OVLB
  1988. X+ 
  1989. X  static int todelay;
  1990. X  
  1991. X! #endif /*OVLB */
  1992. X! 
  1993. X! #ifndef OVLB
  1994. X! 
  1995. X! OSTATIC long takeoff_mask, taking_off;
  1996. X! 
  1997. X! #else /* OVLB */
  1998. X! 
  1999. X! XSTATIC long takeoff_mask = 0L, taking_off = 0L;
  2000. X! 
  2001. X  static const long takeoff_order[] = { WORN_BLINDF, 1L, /* weapon */
  2002. X      WORN_SHIELD, WORN_GLOVES, LEFT_RING, RIGHT_RING, WORN_CLOAK,
  2003. X      WORN_HELMET, WORN_AMUL, WORN_ARMOR,
  2004. X***************
  2005. X*** 15,20 ****
  2006. X--- 26,51 ----
  2007. X  #endif
  2008. X      WORN_BOOTS, 0L };
  2009. X  
  2010. X+ static void FDECL(on_msg, (struct obj *));
  2011. X+ #ifndef OVERLAY
  2012. X+ static int NDECL(Armor_on);
  2013. X+ static int NDECL(Boots_on);
  2014. X+ #endif
  2015. X+ static int NDECL(Cloak_on);
  2016. X+ #ifndef OVERLAY
  2017. X+ static int NDECL(Helmet_on);
  2018. X+ static int NDECL(Gloves_on);
  2019. X+ #endif
  2020. X+ static void NDECL(Amulet_on);
  2021. X+ static void FDECL(Ring_off_or_gone, (struct obj *, BOOLEAN_P));
  2022. X+ #ifndef OVERLAY
  2023. X+ static int FDECL(select_off, (struct obj *));
  2024. X+ #endif
  2025. X+ static struct obj *NDECL(do_takeoff);
  2026. X+ #ifndef OVERLAY
  2027. X+ static int NDECL(take_off);
  2028. X+ #endif
  2029. X+ 
  2030. X  void
  2031. X  off_msg(otmp) register struct obj *otmp; {
  2032. X      if(flags.verbose)
  2033. X***************
  2034. X*** 348,353 ****
  2035. X--- 379,385 ----
  2036. X      You("wield the cockatrice corpse in your bare %s.",
  2037. X          makeplural(body_part(HAND)));
  2038. X      You("turn to stone...");
  2039. X+     killer_format = KILLED_BY_AN;
  2040. X      killer = "cockatrice corpse";
  2041. X      done(STONING);
  2042. X      }
  2043. X***************
  2044. X*** 398,403 ****
  2045. X--- 430,436 ----
  2046. X  /* This must be done in worn.c, because one of the possible intrinsics conferred
  2047. X   * is fire resistance, and we have to immediately set HFire_resistance in worn.c
  2048. X   * since worn.c will check it before returning.
  2049. X+  */
  2050. X  #ifndef OVERLAY
  2051. X  static 
  2052. X  #endif
  2053. X***************
  2054. X*** 406,412 ****
  2055. X  {
  2056. X      return 0;
  2057. X  }
  2058. X-  */
  2059. X  
  2060. X  int
  2061. X  Armor_off()
  2062. X--- 439,444 ----
  2063. X***************
  2064. X*** 467,474 ****
  2065. X--- 499,516 ----
  2066. X          regularize(SAVEF+7);
  2067. X          Strcat(SAVEF, ";1");
  2068. X  #else
  2069. X+ # ifdef MSDOS
  2070. X+         (void)strcpy(SAVEF, SAVEP);
  2071. X+         {
  2072. X+             int i = strlen(SAVEF);
  2073. X+             (void)strncat(SAVEF, plname, 8);
  2074. X+             regularize(SAVEF+i);
  2075. X+         }
  2076. X+         (void)strcat(SAVEF, ".sav");
  2077. X+ # else
  2078. X          Sprintf(SAVEF, "save/%d%s", getuid(), plname);
  2079. X          regularize(SAVEF+5);        /* avoid . or / in name */
  2080. X+ # endif
  2081. X  #endif
  2082. X  #ifdef WIZARD
  2083. X          }
  2084. X***************
  2085. X*** 558,563 ****
  2086. X--- 600,606 ----
  2087. X              Your("body takes on a %s transparency...",
  2088. X                  Hallucination ? "normal" : "strange");
  2089. X          }
  2090. X+         break;
  2091. X      case RIN_ADORNMENT:
  2092. X          ABON(A_CHA) += obj->spe;
  2093. X          flags.botl = 1;
  2094. X***************
  2095. X*** 699,705 ****
  2096. X  /* called in main to set intrinsics of worn start-up items */
  2097. X  void
  2098. X  set_wear() {
  2099. X! /*    if (uarm)  (void) Armor_on(); */
  2100. X      if (uarmc) (void) Cloak_on();
  2101. X      if (uarmf) (void) Boots_on();
  2102. X      if (uarmg) (void) Gloves_on();
  2103. X--- 742,748 ----
  2104. X  /* called in main to set intrinsics of worn start-up items */
  2105. X  void
  2106. X  set_wear() {
  2107. X!     if (uarm)  (void) Armor_on();
  2108. X      if (uarmc) (void) Cloak_on();
  2109. X      if (uarmf) (void) Boots_on();
  2110. X      if (uarmg) (void) Gloves_on();
  2111. X***************
  2112. X*** 711,728 ****
  2113. X  donning(otmp)
  2114. X  register struct obj *otmp;
  2115. X  {
  2116. X!     return (otmp == uarmf && afternmv == Boots_on)
  2117. X!     || (otmp == uarmh && afternmv == Helmet_on)
  2118. X!     || (otmp == uarmg && afternmv == Gloves_on)
  2119. X! /*    || (otmp == uarm && afternmv == Armor_on)*/;
  2120. X  }
  2121. X  
  2122. X  static const char clothes[] = {ARMOR_SYM, 0};
  2123. X  static const char accessories[] = {RING_SYM, AMULET_SYM, TOOL_SYM, 0};
  2124. X  
  2125. X  int
  2126. X  dotakeoff() {
  2127. X      register struct obj *otmp;
  2128. X      int armorpieces = 0;
  2129. X  
  2130. X  #define MOREARM(x) if (x) { armorpieces++; otmp = x; }
  2131. X--- 754,788 ----
  2132. X  donning(otmp)
  2133. X  register struct obj *otmp;
  2134. X  {
  2135. X!     return (otmp == uarmf && (afternmv == Boots_on || afternmv == Boots_off))
  2136. X!     || (otmp == uarmh && (afternmv == Helmet_on || afternmv == Helmet_off))
  2137. X!     || (otmp == uarmg && (afternmv == Gloves_on || afternmv == Gloves_off))
  2138. X!     || (otmp == uarm && (afternmv == Armor_on || afternmv == Armor_off));
  2139. X  }
  2140. X  
  2141. X+ void
  2142. X+ cancel_don()
  2143. X+ {
  2144. X+     /* the piece of armor we were donning/doffing has vanished, so stop
  2145. X+      * wasting time on it (and don't dereference it when donning would
  2146. X+      * otherwise finish)
  2147. X+      */
  2148. X+     afternmv = 0;
  2149. X+     nomovemsg = NULL;
  2150. X+     multi = 0;
  2151. X+ }
  2152. X+ 
  2153. X  static const char clothes[] = {ARMOR_SYM, 0};
  2154. X  static const char accessories[] = {RING_SYM, AMULET_SYM, TOOL_SYM, 0};
  2155. X  
  2156. X  int
  2157. X  dotakeoff() {
  2158. X+ #ifdef __GNULINT__
  2159. X+     register struct obj *otmp = 0;
  2160. X+         /* suppress "may be used uninitialized" warning */
  2161. X+ #else
  2162. X      register struct obj *otmp;
  2163. X+ #endif
  2164. X      int armorpieces = 0;
  2165. X  
  2166. X  #define MOREARM(x) if (x) { armorpieces++; otmp = x; }
  2167. X***************
  2168. X*** 782,788 ****
  2169. X--- 842,853 ----
  2170. X  
  2171. X  int
  2172. X  doremring() {
  2173. X+ #ifdef __GNULINT__
  2174. X+     register struct obj *otmp = 0;
  2175. X+         /* suppress "may be used uninitialized" warning */
  2176. X+ #else
  2177. X      register struct obj *otmp;
  2178. X+ #endif
  2179. X      int Accessories = 0;
  2180. X  
  2181. X  #define MOREACC(x) if (x) { Accessories++; otmp = x; }
  2182. X***************
  2183. X*** 1017,1023 ****
  2184. X          if(is_boots(otmp)) afternmv = Boots_on;
  2185. X          if(is_helmet(otmp)) afternmv = Helmet_on;
  2186. X          if(is_gloves(otmp)) afternmv = Gloves_on;
  2187. X! /*        if(otmp == uarm) afternmv = Armor_on; */
  2188. X          nomovemsg = "You finish your dressing maneuver.";
  2189. X      } else {
  2190. X          if(is_cloak(otmp)) (void) Cloak_on();
  2191. X--- 1082,1088 ----
  2192. X          if(is_boots(otmp)) afternmv = Boots_on;
  2193. X          if(is_helmet(otmp)) afternmv = Helmet_on;
  2194. X          if(is_gloves(otmp)) afternmv = Gloves_on;
  2195. X!         if(otmp == uarm) afternmv = Armor_on;
  2196. X          nomovemsg = "You finish your dressing maneuver.";
  2197. X      } else {
  2198. X          if(is_cloak(otmp)) (void) Cloak_on();
  2199. X***************
  2200. X*** 1144,1151 ****
  2201. X--- 1209,1220 ----
  2202. X      return(1);
  2203. X  }
  2204. X  
  2205. X+ #endif /* OVLB */
  2206. X+ 
  2207. X  #define ARM_BONUS(obj)    ((10 - objects[obj->otyp].a_ac) + obj->spe)
  2208. X  
  2209. X+ #ifdef OVL0
  2210. X+ 
  2211. X  void
  2212. X  find_ac() {
  2213. X      register int uac = 10;
  2214. X***************
  2215. X*** 1172,1177 ****
  2216. X--- 1241,1249 ----
  2217. X      }
  2218. X  }
  2219. X  
  2220. X+ #endif /* OVL0 */
  2221. X+ #ifdef OVLB
  2222. X+ 
  2223. X  void
  2224. X  glibr()
  2225. X  {
  2226. X***************
  2227. X*** 1431,1439 ****
  2228. X--- 1503,1517 ----
  2229. X      return(1);        /* get busy */
  2230. X  }
  2231. X  
  2232. X+ #endif /* OVLB */
  2233. X+ #ifdef OVL1
  2234. X+ 
  2235. X  void
  2236. X  reset_remarm() { taking_off = takeoff_mask =0L; }
  2237. X  
  2238. X+ #endif /* OVL1 */
  2239. X+ #ifdef OVLB
  2240. X+ 
  2241. X  int
  2242. X  doddoremarm() {
  2243. X  
  2244. X***************
  2245. X*** 1460,1465 ****
  2246. X--- 1538,1545 ----
  2247. X          (void) Cloak_off();
  2248. X          useup(otmp);
  2249. X      } else if((otmp = uarm) && (!atmp || atmp == uarm)) {
  2250. X+         /* may be disintegrated by spell or dragon breath... */
  2251. X+         if (donning(otmp)) cancel_don();
  2252. X          Your("armor turns to dust and falls to the floor!");
  2253. X          (void) Armor_gone();
  2254. X          useup(otmp);
  2255. X***************
  2256. X*** 1469,1483 ****
  2257. X--- 1549,1566 ----
  2258. X          useup(otmp);
  2259. X  #endif
  2260. X      } else if((otmp = uarmh) && (!atmp || atmp == uarmh)) {
  2261. X+         if (donning(otmp)) cancel_don();
  2262. X          Your("helmet turns to dust and is blown away!");
  2263. X          (void) Helmet_off();
  2264. X          useup(otmp);
  2265. X      } else if((otmp = uarmg) && (!atmp || atmp == uarmg)) {
  2266. X+         if (donning(otmp)) cancel_don();
  2267. X          Your("gloves vanish!");
  2268. X          (void) Gloves_off();
  2269. X          useup(otmp);
  2270. X          selftouch("You");
  2271. X      } else if((otmp = uarmf) && (!atmp || atmp == uarmf)) {
  2272. X+         if (donning(otmp)) cancel_don();
  2273. X          Your("boots disintegrate!");
  2274. X          (void) Boots_off();
  2275. X          useup(otmp);
  2276. X***************
  2277. X*** 1505,1507 ****
  2278. X--- 1588,1592 ----
  2279. X          flags.botl = 1;
  2280. X      }
  2281. X  }
  2282. X+ 
  2283. X+ #endif /* OVLB */
  2284. X*** src/Old/ioctl.c    Mon Feb 19 18:07:10 1990
  2285. X--- src/ioctl.c    Wed Jan 31 19:54:07 1990
  2286. X***************
  2287. X*** 11,31 ****
  2288. X  #define MONFLAG_H
  2289. X  #include "hack.h"
  2290. X  
  2291. X! #if defined(BSD) || defined(ULTRIX)
  2292. X  #include    <sgtty.h>
  2293. X  struct ltchars ltchars;
  2294. X  struct ltchars ltchars0 = { -1, -1, -1, -1, -1, -1 }; /* turn all off */
  2295. X  #else
  2296. X  #include    <termio.h>    /* also includes part of <sgtty.h> */
  2297. X  struct termio termio;
  2298. X! #ifdef AMIX
  2299. X  #include <sys/ioctl.h>
  2300. X! #endif /* AMIX */
  2301. X  #endif
  2302. X  
  2303. X  void
  2304. X  getioctls() {
  2305. X! #if defined(BSD) || defined(ULTRIX)
  2306. X      (void) ioctl(fileno(stdin), (int) TIOCGLTC, (char *) <chars);
  2307. X      (void) ioctl(fileno(stdin), (int) TIOCSLTC, (char *) <chars0);
  2308. X  #else
  2309. X--- 11,35 ----
  2310. X  #define MONFLAG_H
  2311. X  #include "hack.h"
  2312. X  
  2313. X! #if defined(BSD) || defined(ULTRIX) || defined(HPUX)
  2314. X! # ifdef HPUX
  2315. X! #include    <bsdtty.h>
  2316. X! # else
  2317. X  #include    <sgtty.h>
  2318. X+ # endif
  2319. X  struct ltchars ltchars;
  2320. X  struct ltchars ltchars0 = { -1, -1, -1, -1, -1, -1 }; /* turn all off */
  2321. X  #else
  2322. X  #include    <termio.h>    /* also includes part of <sgtty.h> */
  2323. X  struct termio termio;
  2324. X! # ifdef AMIX
  2325. X  #include <sys/ioctl.h>
  2326. X! # endif /* AMIX */
  2327. X  #endif
  2328. X  
  2329. X  void
  2330. X  getioctls() {
  2331. X! #if defined(BSD) || defined(ULTRIX) || defined(HPUX)
  2332. X      (void) ioctl(fileno(stdin), (int) TIOCGLTC, (char *) <chars);
  2333. X      (void) ioctl(fileno(stdin), (int) TIOCSLTC, (char *) <chars0);
  2334. X  #else
  2335. X***************
  2336. X*** 56,62 ****
  2337. X  
  2338. X  void
  2339. X  setioctls() {
  2340. X! #if defined(BSD) || defined(ULTRIX)
  2341. X      (void) ioctl(fileno(stdin), (int) TIOCSLTC, (char *) <chars);
  2342. X  #else
  2343. X      /* Now modified to run under Sys V R3.    - may have to be #ifdef'ed */
  2344. X--- 60,66 ----
  2345. X  
  2346. X  void
  2347. X  setioctls() {
  2348. X! #if defined(BSD) || defined(ULTRIX) || defined(HPUX)
  2349. X      (void) ioctl(fileno(stdin), (int) TIOCSLTC, (char *) <chars);
  2350. X  #else
  2351. X      /* Now modified to run under Sys V R3.    - may have to be #ifdef'ed */
  2352. X
  2353. END_OF_FILE
  2354. if test 55250 -ne `wc -c <'patch7.02'`; then
  2355.     echo shar: \"'patch7.02'\" unpacked with wrong size!
  2356. fi
  2357. # end of 'patch7.02'
  2358. echo shar: End of archive 30 \(of 30\).
  2359. cp /dev/null ark1isdone
  2360. MISSING=""
  2361. for I in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 ; do
  2362.     if test ! -f ark${I}isdone ; then
  2363.     MISSING="${MISSING} ${I}"
  2364.     fi
  2365. done
  2366. if test "${MISSING}" = "" ; then
  2367.     echo You have unpacked all 30 archives.
  2368.     rm -f ark[1-9]isdone ark[1-9][0-9]isdone
  2369. else
  2370.     echo You still need to unpack the following archives:
  2371.     echo "        " ${MISSING}
  2372. fi
  2373. ##  End of shell archive.
  2374. exit 0
  2375.